__author__ = 'yejinlei_cn@qq.com'

from pydp import pyFactoryMethod

class pyStrategy:
    ''' Strategy '''

    def __new__(cls, obj):
        '''return object of obj

        :type obj: must a object
        :rtype: object of obj
        '''
        return obj

#test
class Father:
    def show(self):
        pass

class Son(Father):
    def show(self):
        print("I'm a Boy")

class Daughter(Father):
    def show(self):
        print("I'm a girl")

if __name__ == '__main__':
    son = Son()
    f = pyStrategy(son)
    f.show()

    daughter = Daughter()
    f = pyStrategy(daughter)
    f.show()

